package org.datacoder.geocoding.datastructures.rectangles

import org.datacoder.geocoding.datastructures.geoshapes.*
import org.datacoder.geocoding.datastructures.util.*
import org.datacoder.geocoding.jurisdiction.*

class SegmentTreeNode {

    SegmentTreeNode left = null
    SegmentTreeNode right = null
    double leftValue
    double rightValue

    Set<Jurisdiction> jurisdictions

    public SegmentTreeNode(){
        jurisdictions = new HashSet<Jurisdiction>()
    }
    public boolean containsPoint(double point){
        return ((leftValue <= point) && (point <= rightValue))
    }
    public void addJurisdiction(Jurisdiction juris){
        jurisdictions.add(juris)
    }
    
}

